package rjgc.mall.service;

import rjgc.mall.entity.Goods;
import rjgc.mall.entity.ShoppingCart;
import rjgc.mall.entity.vo.ShoppingCarList;

import java.util.List;

public interface ShoppingCartService {
    public int AddToShoppingCart(Integer userid,Goods good);
    public int RemoveFromShoppingCart(Integer id);
    public int RemoveFromShoppingCartByStatus(Integer userid);

    public List<ShoppingCart> ShowUserShoppingCart(Integer userid);

    public int SelectAll(Integer userid);
    public int NotSelectAll(Integer userid);
    public int SelectOneOrNot(Integer id);

    ShoppingCarList viewList(Integer userId);
    //购买已选择商品
    public int BuySelectedGoods(Integer userid,String tradetime,String tradeplace);
    //将已选择商品加入收藏
    public int MoveToCollection(Integer userid);

    //多选购买重置版
    public int BuySelectedGoods2(Integer userid,String tradetime,String tradeplace);

    //设置购买数量
    public  int SetBuyNum(Integer id ,Integer userid , Integer num);
}
